﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;

namespace SmallTalk
{
    public partial class Form1 : Form
    {
        public Form1()
        {
            InitializeComponent();
        }

        private void Form1_Load(object sender, EventArgs e)
        {
            timer1.Interval = RandomNumber(10000, 10000); //between 10 and 1000 seconds norm, now its 10 and 10 so we can debug quick
            MessageBox.Show(timer1.Interval.ToString()); //purely for debugging
        }
        private int RandomNumber(int min, int max)
        {
            Random random = new Random();
            return random.Next(min, max);
        }

        private void timer1_Tick(object sender, EventArgs e)
        {
            var asker = new asker();
            asker.Show();
            timer1.Interval = RandomNumber(10000,10000); //again, normally between 10 and 1000 seconds, but now 10 and 10
        }
    }
}
